package com.example.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.example.domain.Goods;
import com.baomidou.mybatisplus.extension.service.IService;
import com.example.domain.User;
import com.example.domain.paging.PageHelper;
import com.example.util.Result;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author author
 * @since 2024-04-16
 */
public interface IGoodsService extends IService<Goods> {
    int addGoods(Goods goods);

    int deleteGoods(int id);

    List<Goods> selectByCategory(String category);

    Goods selectById(Goods good);

    List<Goods> selectAllG(Integer uid);

    Goods selectByGoods(Goods goods);

    IPage<Goods> getPage(int currentPage, int pageSize, Goods goods);
    
    //更新库存
    Result updateStock(Goods goods);

}
